<%@ page contentType="text/html;charset=utf-8" language="java"%>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html:html>
<head>
	<META http-equiv=Content-Type content="text/html; charset=utf-8">
	<LINK href="../styles/stylewang.css" type=text/css rel=stylesheet>
	<LINK href="styles/stylewang.css" type=text/css rel=stylesheet>
	<LINK href="../../styles/stylewang.css" type=text/css rel=stylesheet>
	<LINK href="xtree.css" type=text/css rel=stylesheet>
	<style type="text/css"></style>
	<script language=javascript>
			function showTaskInfo(id){
				top.B.location.href="frame.do?Frame=12&Id=16&"+value;
			}
		
		</script>
	<title>CGProject</title>
	<html:base />
</head>
<%
	String statusId = (String) request.getAttribute("StatusId");
%>
<body topmargin="0" leftmargin="0" rightmargin="0" bottommargin="0"
	marginwidth="0" marginheight="0">
	<table border="0" width="445" cellspacing="0" cellpadding="0"
		id="table6" height="59">
		<%--	
	<tr>
		<td width="150" valign="middle" id="leftcenter">&nbsp;&nbsp;<bean:message key="confirm.selecttype"/></td>
		<td width="178" id="leftcenter" ><html:form action="/selectType" ><html:select property="type" style="border:1px solid #C0C0C0; font-family: Tahoma;font-size: 11px" onchange="submitSelectType()">
		<html:option value="Task"><bean:message key="task"/></html:option>
	  	<html:option value="Make">Make</html:option>  
		</html:select></html:form></td>
		<td  id="rightcenter" width="250">&nbsp;<font color="990000"><bean:message key="currenttype"/> : <bean:write name="Type"/></font></td>
	</tr>
 --%>
		<tr>
			<td id="leftcenter">
				&nbsp;&nbsp;
				<bean:message key="confirm.selecttype" />
			</td>
			<td id="rightcenter">
				<logic:equal name="Type" value="Task">
					<html:form action="/filterConfirm">
						<html:select property="statusId"
							style="border:1px solid #C0C0C0; font-family: Tahoma; font-size: 11px"
							onchange="submitFilterConfirm()">
							<html:option value="4">
								<bean:message key="WaitingConfirm" />
							</html:option>
							<html:option value="5">
								<bean:message key="ConfirmNotPassed" />
							</html:option>
							<html:option value="6">
								<bean:message key="ConfirmPassed" />
							</html:option>
							<html:option value="7">
								<bean:message key="Finished" />
							</html:option>
						</html:select>
					</html:form>
				</logic:equal>
				<logic:equal name="Type" value="Make">
					<html:form action="/filterConfirm">
						<html:select property="statusId"
							style="border:1px solid #C0C0C0; font-family: Tahoma; font-size: 11px"
							onchange="submitFilterConfirm()">
							<html:option value="18">
								<bean:message key="WaitingConfirm" />
							</html:option>
							<html:option value="22">
								<bean:message key="ConfirmNotPassed" />
							</html:option>
							<html:option value="23">
								<bean:message key="ConfirmPassed" />
							</html:option>
						</html:select>
					</html:form>
				</logic:equal>
			</td>
		</tr>
		<tr>
			<td  colspan="2" id="tdtop">
			  &nbsp;
      		</td>
      	</tr>
	</table>
	<logic:equal name="Type" value="Task">
		<logic:notEmpty name="ElementUnits">

			<table border="0" width="445" cellspacing="0" id="table6">
				<tr>
					<td id="btleftbian">
						&nbsp;
						<b><bean:message key="element" /> <bean:message key="taskname" /> </b>
					</td>
					<td id="btcenterbian">
						&nbsp;
						<b><bean:message key="producer" /> </b>
					</td>
					<td id="btrightbian">
						&nbsp;VersionNo
					</td>
				</tr>

				<logic:iterate name="ElementUnits" id="element">
					<logic:equal name="element" property="status.statusId"
						value="<%=statusId%>">
						<tr>
							<td id="leftcenter">
								&nbsp;
								<html:link target="right" page="/intoConFirm.do?Type=Task"
									paramId="Id" paramName="element" paramProperty="taskId">
									<bean:write name="element" property="taskName" />
								</html:link>
							</td>
							<td id="leftcenter">
								&nbsp;
								<bean:write name="element" property="reguser.regName" />
							</td>

							<td id="rightcenter">
								<c:out value="${element.versionNo -1}"/>&nbsp;
								<logic:equal name="element" property="isConfirmed" value="1">
									<font color="00FF00"><bean:message
											key="confirm.alreadypass" /> </font>
								</logic:equal>
							</td>
					</tr>
					</logic:equal>
				</logic:iterate>
				<tr>
					<td colspan="3" id="tdtop">
						&nbsp;
					</td>
				</tr>
			</table>
		</logic:notEmpty>
		<logic:notEmpty name="ShotUnits">
			<table border="0" width="445" cellspacing="0" id="table6">
				<tr>
					<td id="btleftbian">
						&nbsp;
						<b><bean:message key="shot" /> <bean:message key="taskname" />
						</b>
					</td>
					<td id="btcenterbian">
						&nbsp;
						<b><bean:message key="producer" /> </b>
					</td>
					<td id="btrightbian">
						&nbsp;VersionNo
					</td>

				</tr>

				<logic:iterate name="ShotUnits" id="element">
					<logic:equal name="element" property="status.statusId"
						value="<%=statusId%>">
						<tr>
							<td id="leftcenter">
								&nbsp;
								<html:link target="right" page="/intoConFirm.do?Type=Task"
									paramId="Id" paramName="element" paramProperty="taskId">
									<bean:write name="element" property="taskName" />
								</html:link>
							</td>
							<td id="leftcenter">
								&nbsp;
								<bean:write name="element" property="reguser.regName" />
							</td>

							<td id="rightcenter">
								<c:out value="${element.versionNo -1}"/>&nbsp;
								<logic:equal name="element" property="isConfirmed" value="1">
									<font color="00FF00"><bean:message
											key="confirm.alreadypass" /> </font>
								</logic:equal>
							</td>
					</tr>
					</logic:equal>
				</logic:iterate>
				<tr>
					<td colspan="3" id="tdtop">
						&nbsp;
					</td>
				</tr>
			</table>
		</logic:notEmpty>
	</logic:equal>


	<logic:equal name="Type" value="Make">
		<table border="0" width="445" cellspacing="0" id="table6">
				<logic:notEmpty name="ElementUnits">
					<tr>
						<td id="btleftbian" colspan="2">
							&nbsp;
							<b><bean:message key="element" /> &nbsp;<bean:message
									key="taskname" />
							</b>
						</td>
						<td id="btrightbian">
							&nbsp;
							<b><bean:message key="confirm.status" />
							</b>
						</td>

					</tr>
				</logic:notEmpty>
				<logic:iterate name="ElementUnits" id="element">
					<logic:equal name="element" property="status.statusId"
						value="<%=statusId%>">
						<tr>
							<td id="leftcenter" colspan="2">
								&nbsp;
								<bean:write name="element" property="makeName" />
							</td>
							<td id="righttcenter">
								&nbsp;
								<logic:equal name="element" property="isConfirmed" value="1">
									<html:link target="right"
										page="/intoConFirm.do?Status=CA&Type=Make" paramId="Id"
										paramName="element" paramProperty="makeId">
										<font color="A0A0A0"><bean:message
												key="confirm.alreadypass" /> </font>
									</html:link>
								</logic:equal>
								<logic:notEqual name="element" property="isConfirmed" value="1">
									<html:link target="right"
										page="/intoConFirm.do?Status=C&Type=Make" paramId="Id"
										paramName="element" paramProperty="makeId">
										<font color="990000"><bean:message key="confirm" /> </font>
									</html:link>
								</logic:notEqual>
							</td>

						</tr>
					</logic:equal>
				</logic:iterate>
				<tr>
					<td colspan="3" id="tdtop">
						&nbsp;
					</td>
				</tr>
		</table>
		<table border="0" width="445" cellspacing="0" id="table6">
			<logic:notEmpty name="ShotUnits">
				<tr>
					<td id="btleftbian" colspan="2">
						&nbsp;
						<b><bean:message key="shot" /> &nbsp;<bean:message
								key="makename" />
						</b>
					</td>
					<td id="btrightbian">
						&nbsp;
						<b><bean:message key="confirm.status" />
						</b>
					</td>
				</tr>
			</logic:notEmpty>
			<logic:iterate name="ShotUnits" id="element">
				<logic:equal name="element" property="status.statusId"
					value="<%=statusId%>">
					<tr>
						<td id="leftcenter" colspan="2">
							&nbsp;
							<bean:write name="element" property="makeName" />
						</td>
						<td id="rightcenter">
							&nbsp;
							<logic:equal name="element" property="isConfirmed" value="1">
								<html:link target="right"
									page="/intoConFirm.do?Status=CA&Type=Make" paramId="Id"
									paramName="element" paramProperty="makeId">
									<font color="A0A0A0"><bean:message
											key="confirm.alreadypass" /> </font>
								</html:link>
							</logic:equal>
							<logic:notEqual name="element" property="isConfirmed" value="1">
								<html:link target="right"
									page="/intoConFirm.do?Status=C&Type=Make" paramId="Id"
									paramName="element" paramProperty="makeId">
									<font color="990000"><bean:message key="confirm" /> </font>
								</html:link>
							</logic:notEqual>
						</td>

					</tr>
				</logic:equal>
			</logic:iterate>
			<tr>
				<td colspan="3" id="tdtop">
					&nbsp;
				</td>
			</tr>
			

		</table>
	</logic:equal>
</body>
</html:html>
<script language="javascript">
function submitSelectType()
{
	window.document.selectTypeForm.submit();
}
function submitFilterConfirm()
{
	window.document.filterConfirmForm.submit();
}

function openwin(url)
{
	window.open(url,'newwindow','width=400,height=200');

}

</script>